var money = '￥20';
var num= money.replace(/[^0-9]/ig,"");
document.write(num);
/*
alert(money)
function updateNum(money){
    var isnum = /^\d+$/.test(money);
    if (isnum){
        return isnum;
    }else {
        for (a=0;a<money.length-1;a++){

        }

    }
}
document.write(parseInt(money))*/
